﻿using UnityEngine;
using System.Collections;

namespace Battle
{
    public class RoundEffectKit : MonoBehaviour
    {
        public GameObject playerRound;
        public GameObject enemyRound;
        public GameObject mask;
        public void Hide()
        {
            playerRound.SetActive(false);
            enemyRound.SetActive(false);
            mask.SetActive(false);

        }
        public void ShowRound(int roundIndex)
        {
            CancelInvoke();
            if(roundIndex == 1)
            {
                playerRound.SetActive(false);
                enemyRound.SetActive(true);
                AudioManager.Instance.PlayUIAudio("guard_phase");
            }
            else if (roundIndex == 0)
            {
                playerRound.SetActive(true);
                enemyRound.SetActive(false);
                AudioManager.Instance.PlayUIAudio("round_start");
            }
            mask.SetActive(true);
            Invoke("Hide", 1);
        }
        


    }
}